In [1]:
x = polygen(QQ)
K.<i> = NumberField(x^2+1)
In [2]:
E = EllipticCurve([i + 1, i - 1, i + 1, -5*i, 2*i])
show(E)
S = E.conductor().prime_factors()
show(S)
S3 = S + K.primes_above(3)
show(S3)
f3 = E.division_polynomial(3)
show(f3)
In [3]:
%cd /home/jec/CremonaPacetti/code
%runfile S4.py
%runfile T0mod3.py
%runfile T0T1T2.py
In [4]:
T1, A, decoder = get_T1(K,S3)
print("T1:")
for P in T1:
print("{}, norm {}".format(P,P.norm()))
BB = BlackBox_from_elliptic_curve(E)
decoder([0 if BB_det(BB)(P)%3==1 else 1 for P in T1])
Out[4]:
In [5]:
decoder([0 if P.norm()%3==1 else 1 for P in T1])
Out[5]:
In [6]:
xK = polygen(K)
M = K.extension(xK**2+3, 'r3')
In [7]:
S4quartics = S4_extensions_with_quadratic(K,S3,M)
D4quartics = D4_extensions_with_quadratic(K,S3,M)
C4quartics = C4_extensions_with_quadratic(K,S3,M)
quartics = S4quartics+D4quartics+C4quartics
print("There are {} candidate quartics, of which {} are S4, {} are D4 and {} are C4".format(len(quartics),len(S4quartics), len(D4quartics),len(C4quartics)))
In [8]:
_, T0, vlist = get_T0_mod3(K,S3,quartics)
print("The test primes are")
for P in T0:
print("P={} with norm {}".format(P,P.norm()))
In [9]:
aplist = [BB_trace(BB)(P) for P in T0]
v0 = [0 if ap%3==0 else 1 for ap in aplist]
print("The traces for these primes are {}".format(aplist))
print("Test vector = {}".format(v0))
In [10]:
res = [i for i,vi in enumerate(vlist) if v0==vi]
if res:
g3 = quartics[res[0]]
print("The mod 3 representation is irreducible.")
print("The splitting field of the projective representation is defined by the quartic {}".format(g3))
group = 'S4' if g3 in S4quartics else 'D4' if g3 in D4quartics else 'C4'
print("The projective image is isomorphic to {}".format(group))
else:
print("The representation is reducible")
In [11]:
K.extension(f3,'t3').is_isomorphic(K.extension(g3,'u3'))
Out[11]:
In [16]:
!cat /home/jec/bianchi-progs/modularity.in
In [21]:
input_string = "1 36 4 1 1 b 9 4 -2"
import commands
In [67]:
K.primes_of_bounded_norm(100)
Out[67]:
In [66]:
%%writefile /home/jec/bianchi-progs/modularity.py
import subprocess
def ideal_gen_coeffs(I):
return " ".join([str(c) for c in list(I.gens_reduced()[0])])
def apdata(E, P):
ap = E.reduction(P).trace_of_frobenius()
return " ".join([ideal_gen_coeffs(P), str(ap)])
def check_modularity(E, primes, verbose=False):
K = E.base_ring()
field = K.discriminant().squarefree_part().abs()
ab = ideal_gen_coeffs(E.conductor())
np = len(primes)
input_string = " ".join([str(field), ab, "1", str(np)] + [apdata(E,P) for P in primes])
if verbose:
print("input string: {}".format(input_string))
cmd = "echo {} | /home/jec/bianchi-progs/modularity".format(input_string)
if verbose:
print("command line: {}".format(cmd))
pipe = subprocess.Popen(cmd, stdout=subprocess.PIPE, shell=True)
if pipe.returncode:
return None
return pipe.stdout.readlines()[0].replace("\n","")
In [65]:
check_modularity(E,T0)
Out[65]:
In [40]:
Out[40]:
In [13]:
%cd /home/jec/bianchi-progs
#
# Input parameters:
# 1 is the field (d=1, 2, 3, 7, 11 for Q(sqrt(-d)))
# 0 for verbosity level
# 36 4 for the level (36+4i)
# 97 113 ... 197: rational primes for which we compute the a_P for P|p
# 0 to signal no more primes
# 0 0 to signal no more levels
#
!echo "1 0 36 4 97 113 137 149 157 173 181 193 197 0 0 0" | /home/jec/bianchi-progs/moreap1
In [14]:
zip(T0,aplist)
Out[14]:
In [ ]: